package com.entity;

import java.io.Serializable;

/**
 * Created by Administrator on 2017/3/11.
 */
public class Application implements Serializable {
    private ApplicationPK applicationPK;
    private String numbers;

    public ApplicationPK getApplicationPK() {
        return applicationPK;
    }

    public void setApplicationPK(ApplicationPK applicationPK) {
        this.applicationPK = applicationPK;
    }

    public String getNumbers() {
        return numbers;
    }

    public void setNumbers(String numbers) {
        this.numbers = numbers;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        Application that = (Application) o;

        if (applicationPK.getId() != that.applicationPK.getId()) return false;
        if (applicationPK.getAccount() != null ? !applicationPK.getAccount().equals(that.applicationPK.getAccount()) : that.applicationPK.getAccount() != null) return false;
        if (numbers != null ? !numbers.equals(that.numbers) : that.numbers != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = applicationPK.getAccount()  != null ? applicationPK.getAccount() .hashCode() : 0;
        result = 31 * result + applicationPK.getId();
        result = 31 * result + (numbers != null ? numbers.hashCode() : 0);
        return result;
    }
}
